#include "Restaurant.h"


Restaurant::Restaurant(void)
{
	
}
Restaurant::Restaurant(int profit, int tip1, int tip2, int tip3)
{
	this->profit = profit;
	this->tip1 = tip1;
	this->tip2 = tip2;
	this->tip3 = tip3;
}

Restaurant::~Restaurant(void)
{
}
void Restaurant::addOwner(string name, int ID)
{
	lst[0] = new Owner;
	lst[0]->addInfomation(name, ID);
}
void Restaurant::addChiefI(string name, int ID, string cuisine, int i)
{
	Chief* a = new Chief;
	a->addInfomation(name, ID, cuisine);
	lst[i] = a;
}
void Restaurant::addWaiterI(string name, int ID, int tips, int i)
{
	Waiter* a = new Waiter;
	a->addInfomation(name, ID, tips);
	lst[i+2] = a;
}
void Restaurant::caculateSalary()
{
	int i;
	for(i = 0; i < 6;  i++)
		lst[i]->caculateSalary(profit);
}
int Restaurant::getEmployeeSalary(int i)
{
    return lst[i]->getSalary();
}